﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data.SqlClient;

public partial class AgentPage_AgentOrderList : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    protected void ListView_orderstudent_SelectedIndexChanged(object sender, EventArgs e)
    {

    }

    protected void Button_del_Click(object sender, EventArgs e)
    {
        
            string orderid = GridView_order.SelectedDataKey.Value.ToString();
            SqlConnection sqlcon = new SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings["ConnString"].ToString());
            sqlcon.Open();
            Response.Write("<script language=javascript > alert('" + Order.cancel(sqlcon,orderid) + "');</script>");
            sqlcon.Close();
        
    }
}